import React from 'react'
import {Modal, Card, Button} from 'antd'

export default ({title, pic, speech, visible, toNext}) => (
  <Modal visible={visible} closable={false}
         title={`我是${title}`}
         footer={[
           <Button type="primary" icon="double-right"
                   key="nextbtn"
                   onClick={toNext}>
             下一个
           </Button>
         ]}>
    <Card hoverable
          cover={<img alt={title}
                      src={`${process.env.PUBLIC_URL}/pics/${pic}`}/>}>
      <Card.Meta description={speech}/>
    </Card>
  </Modal>
)
